import request from "@/utils/request";

// 首页
export function chart(params) {
  return request({
    url: "/chart",
    method: "get",
    params
  });
}
// 已读
export function unread(params) {
  return request({
    url: "/unread",
    method: "get",
    params
  });
}

export function setIndex(params) {
  return request({
    url: "/setIndex",
    method: "post",
    params
  });
}

export function changeChart(params) {
  return request({
    url: "/changeChart",
    method: "get",
    params
  });
}

export function getList(params) {
  return request({
    url: "/getList",
    method: "get",
    params
  });
}

// 删除单个任务
export function delete_task(params) {
  return request({
    url: "/delete",
    method: "post",
    params
  });
}

// 删除全部任务
export function delete_all(params) {
  return request({
    url: "/deleteAll",
    method: "post",
    params
  });
}

// 修改密码
export function changePassword(params) {
  return request({
    url: "/changePassword",
    method: "post",
    params
  });
}

/* 获取帮助文档 */
export function getDocument(params) {
  return request({
    url: "/document",
    method: "get",
    params
  });
}

export function searchDocument(params) {
  return request({
    url: "/searchDocument",
    method: "get",
    params
  });
}

export function getDocumentInfo(params) {
  return request({
    url: "/documentInfo",
    method: "get",
    params
  });
}

// 更多反馈
export function get_feedback_MoreList(params) {
  return request({
    url: "/getMoreList",
    method: "get",
    params
  });
}
export function get_allRead(params) {
  return request({
    url: "/allRead",
    method: "get",
    params
  });
}

/* 
获取站内通知，当页面获得即使通知，被刷新时，从接口获取
*/
export function get_notification(params) {
  return request({
    url: "/getNotification",
    method: "get",
    params
  });
}

export function delete_notification(params) {
  return request({
    url: "/deleteNotification",
    method: "get",
    params
  });
}

export function read_notification(params) {
  return request({
    url: "/read",
    method: "get",
    params
  });
}

// 更多招标信息
export function getTender(params) {
  return request({
    url: "/getTender",
    method: "get",
    params
  });
}

// 提交意见反馈接口
export function setFeedback(params) {
  return request({
    url: "/feedback",
    method: "post",
    data: params
  });
}

// 获取意见反馈的分类
export function getClassFil(params) {
  return request({
    url: "/feedbackCat",
    method: "get",
    params
  });
}